home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 20 / Cream of the Crop 20 (Terry Blount) (1996).iso / os2 / bind493a.zip / named / Makefile < prev    next >
Makefile  |  1996-06-13  |  7KB  |  197 lines

  1. #
  2.  
  3. #    @(#)Makefile.dist    5.4 (Berkeley) 8/15/90
  4. #    $Id: Makefile,v 8.7 1995/12/22 10:20:30 vixie Exp $
  5. #
  6.  
  7. ## ++Copyright++ 1987, 1988, 1990
  8. ## -
  9. ## Copyright (c) 1987, 1988, 1990
  10. ##    The Regents of the University of California.  All rights reserved.
  11. ## 
  12. ## Redistribution and use in source and binary forms, with or without
  13. ## modification, are permitted provided that the following conditions
  14. ## are met:
  15. ## 1. Redistributions of source code must retain the above copyright
  16. ##    notice, this list of conditions and the following disclaimer.
  17. ## 2. Redistributions in binary form must reproduce the above copyright
  18. ##    notice, this list of conditions and the following disclaimer in the
  19. ##    documentation and/or other materials provided with the distribution.
  20. ## 3. All advertising materials mentioning features or use of this software
  21. ##    must display the following acknowledgement:
  22. ##     This product includes software developed by the University of
  23. ##     California, Berkeley and its contributors.
  24. ## 4. Neither the name of the University nor the names of its contributors
  25. ##    may be used to endorse or promote products derived from this software
  26. ##    without specific prior written permission.
  27. ## 
  28. ## THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  29. ## ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  30. ## IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  31. ## ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  32. ## FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  33. ## DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  34. ## OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  35. ## HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  36. ## LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  37. ## OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  38. ## SUCH DAMAGE.
  39. ## -
  40. ## Portions Copyright (c) 1993 by Digital Equipment Corporation.
  41. ## 
  42. ## Permission to use, copy, modify, and distribute this software for any
  43. ## purpose with or without fee is hereby granted, provided that the above
  44. ## copyright notice and this permission notice appear in all copies, and that
  45. ## the name of Digital Equipment Corporation not be used in advertising or
  46. ## publicity pertaining to distribution of the document or software without
  47. ## specific, written prior permission.
  48. ## 
  49. ## THE SOFTWARE IS PROVIDED "AS IS" AND DIGITAL EQUIPMENT CORP. DISCLAIMS ALL
  50. ## WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES
  51. ## OF MERCHANTABILITY AND FITNESS.   IN NO EVENT SHALL DIGITAL EQUIPMENT
  52. ## CORPORATION BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
  53. ## DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
  54. ## PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
  55. ## ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
  56. ## SOFTWARE.
  57. ## -
  58. ## --Copyright--
  59.  
  60. ## NOTE: customizing this Makefile is almost certainly the wrong thing to do.
  61. ##    unless you are a developer and intend to run "make" here a lot of times
  62. ##    per day, you should just run "make" from the top-level directory after
  63. ##    configuring _that_ Makefile with the right system-dependent values.
  64.  
  65. VER    = 4.9.3-EMX
  66. SHELL    = /bin/sh
  67. DESTDIR =
  68.  
  69. INDOT=
  70. XFER_INDOT=
  71. #(sunos)
  72. #INDOT=in.
  73. #XFER_INDOT=in.
  74.  
  75. HOSTNAMECMD = hostname || uname -n
  76.  
  77. #(these defaults are reasonable for a BSD/OS test environment;
  78. # for real configuration, edit ../Makefile and run make from there.)
  79.  
  80. COMPINCL = ../compat/include
  81. INCL=    ../include
  82. RES=    ../res/libresolv.a
  83. DESTSBIN = ${DESTDIR}/usr/sbin
  84. DESTEXEC = ${DESTDIR}/usr/libexec
  85. PIDDIR = /var/run
  86. CC= cc
  87. #CC= gcc2 -Wimplicit -Wunused -Wreturn-type
  88. SHELL= /bin/sh
  89. CDEBUG= -g
  90. LIBS=
  91. COMPLIB= ../compat/lib/lib44bsd.a
  92. PATH_XFER = ${DESTEXEC}/${XFER_INDOT}named-xfer
  93. DEFS = -D_PATH_XFER=\"${PATH_XFER}\" -D_PATH_PIDFILE=\"${PIDDIR}/named.pid\"
  94. INSTALL = install
  95. PS=ps
  96. IOT=ABRT
  97.  
  98. CFLAGS = ${CDEBUG} -I${INCL} -I${COMPINCL} ${DEFS}
  99.  
  100. HDRS=    db_defs.h db_glob.h ns_defs.h ns_glob.h named.h pathnames.h tree.h
  101. SRCS=    db_dump.c db_load.c db_lookup.c db_reload.c db_save.c db_update.c \
  102.     db_secure.c db_glue.c \
  103.     ns_forw.c ns_init.c ns_main.c ns_maint.c ns_req.c ns_resp.c \
  104.     ns_sort.c ns_stats.c ns_validate.c ns_ncache.c \
  105.     storage.c dmalloc.c tree.c
  106. OBJS=    db_dump.o db_load.o db_lookup.o db_reload.o db_save.o db_update.o \
  107.     db_secure.o db_glue.o \
  108.     ns_forw.o ns_init.o ns_main.o ns_maint.o ns_req.o ns_resp.o \
  109.     ns_sort.o ns_stats.o ns_validate.o ns_ncache.o \
  110.     storage.o dmalloc.o tree.o
  111. XFERSRCS=  named-xfer.c
  112. XFEROBJ=   named-xfer.o db_glue.o storage.o dmalloc.o version.o
  113.  
  114. all: named named-xfer named.reload named.restart ndc
  115.  
  116. named: ${OBJS} ${RES} ${COMPLIB} version.o
  117.     ${CC} ${CDEBUG} ${LDFLAGS} -o $@ version.o ${OBJS} \
  118.         ${RES} ${COMPLIB} ${LIBS}
  119.  
  120. version.o: version.c
  121.  
  122. version.c: version.c.org Makefile ../Makefile ${SRCS} ${HDRS}
  123.     (sed -e "s|%WHEN%|June 1996|" -e "s|%VERSION%|4.9.3-EMX|" \
  124.         -e "s|%WHOANDWHERE%|ported to OS/2 by pmeerw@cosy.sbg.ac.at|" \
  125.         < version.c.org > version.c)
  126.  
  127. named.reload: named.reload.sh Makefile
  128.     sed -e "s|%INDOT%|${INDOT}|" \
  129.         -e "s|%DESTSBIN%|${DESTSBIN}|" \
  130.         < named.reload.sh > named.reload
  131.     chmod +x named.reload
  132.  
  133. named.restart: named.restart.sh Makefile
  134.     sed -e "s|%INDOT%|${INDOT}|" \
  135.         -e "s|%DESTSBIN%|${DESTSBIN}|" \
  136.         < named.restart.sh > named.restart
  137.     chmod +x named.restart
  138.  
  139. ndc: ndc.sh Makefile
  140.     sed -e "s|%PIDDIR%|${PIDDIR}|" \
  141.         -e "s|%INDOT%|${INDOT}|" \
  142.         -e "s|%PS%|${PS}|" \
  143.         -e "s|%IOTPS%|${IOT}|" \
  144.         -e "s|%DESTSBIN%|${DESTSBIN}|" \
  145.         -e "s|%IOT%|${IOT}|" \
  146.         < ndc.sh > ndc
  147.     chmod +x ndc
  148.  
  149. named-xfer:    ${XFEROBJ} ${RES} ${COMPLIB}
  150.     ${CC} ${CDEBUG} ${LDFLAGS} -o $@ ${XFEROBJ} \
  151.         ${RES} ${COMPLIB} ${LIBS}
  152.  
  153. centerline_named:
  154.     #load -I${INCL} -I${COMPINCL} ${CFLAGS} ${SRCS} \
  155.         version.c ${RES} ${COMPLIB} ${LIBS}
  156.  
  157. centerline_obj:
  158.     #load -I${INCL} -I${COMPINCL} ${CFLAGS} ${OBJS} \
  159.         version.o ${RES} ${COMPLIB} ${LIBS}
  160.  
  161. centerline_xfer:
  162.     #load -DXFER ${CFLAGS} ${XFERSRCS} ${RES} ${COMPLIB} ${LIBS}
  163.  
  164. clean:
  165.     rm -f ${OBJS} ${XFEROBJ} core named named-xfer version.o version.c
  166.     rm -f *~ *.BAK *.CKP
  167.     rm -f tags .depend core named.reload named.restart ndc
  168.     rm -f *.orig
  169.  
  170. depend .depend: ${SRCS} ${XFERSRCS}
  171.     mkdep ${CPPFLAGS} -I${INCL} -I${COMPINCL} ${SRCS} ${XFERSRCS}
  172.  
  173. install:
  174.     ${INSTALL} -c -s -o bin -g bin -m 555 \
  175.         named ${DESTDIR}${DESTSBIN}/${INDOT}named
  176.     ${INSTALL} -c -s -o bin -g bin -m 555 \
  177.         named-xfer ${DESTDIR}${PATH_XFER}
  178.     ${INSTALL} -c -o bin -g bin -m 555 \
  179.         named.restart ${DESTDIR}${DESTSBIN}/${INDOT}named.restart
  180.     ${INSTALL} -c -o bin -g bin -m 555 \
  181.         named.reload ${DESTDIR}${DESTSBIN}/${INDOT}named.reload
  182.     ${INSTALL} -c -o bin -g bin -m 555 \
  183.         ndc ${DESTDIR}${DESTSBIN}/${INDOT}ndc
  184.     @echo "*** Install symlinks if needed ***"
  185.  
  186. lint: ${SRCS} ${HDRS} ${XFERSRCS}
  187.     lint -x -Dlint ${CFLAGS} ${SRCS} ${XFERSRCS} 2>&1 \
  188.         | grep -v 'warning: nested comments not supported'
  189.  
  190. tags: ${SRCS} ${XFERSRCS} Makefile
  191.     ctags -t `echo ${SRCS} ${HDRS} ${XFERSRCS}|tr ' ' '\012'|sort -u`
  192.  
  193. $(SRCS):: $(HDRS)
  194.  
  195. # DO NOT DELETE THIS LINE -- mkdep uses it.
  196. # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
  197.